package com.tyc.mb.test.demo6;

import org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor;
import org.springframework.context.support.GenericApplicationContext;

public class Application06 {
    public static void main(String[] args) {
        GenericApplicationContext applicationContext = new GenericApplicationContext();
        applicationContext.registerBean("myBean",MyBean.class);
        // 初始化
        applicationContext.registerBean(AutowiredAnnotationBeanPostProcessor.class);
        applicationContext.refresh();
        System.out.println(applicationContext.getBean(MyBean.class).getApplicationContext());
    }
}
